# generate 100 random numbers for x and y
x = np.random.randn(1000)
y = np.random.randn(1000)
# if x is smaller than 0 make it red
# if x is larger than 0 make it blue
colors = ['red' if i < 0 else 'blue' for i in x]
# create a scatter plot
fig = px.scatter(x=x, y=y, color=colors)
# render the plot
plotly.offline.iplot(fig)